Recursion from Iteration
نویسنده
چکیده
In a simply-typed, call-by-value (CBV) language with rst-class continuations , the usual CBV xpoint operator can be deened in terms of a simple, innnitely-looping iteration primitive. We rst consider a natural but awed deenition, based on exceptions and \iterative deepening" of nite unfoldings, and point out some of its shortcomings. Then we present the proper construction using full rst-class continuations , with both an informal derivation and a proof that the behavior of the deened operator faithfully mimics a \built-in" recursion primitive. In fact, given an additional uniformity assumption, the construction is a two-sided inverse of the usual deenition of iteration from recursion. Continuing, we show that the CBV looping primitive is in fact the direct-style equivalent of a continuation-passing-style xpoint, and that this correspondence extends all the way to traditional deenitions of these operators in terms of reeexive types.
منابع مشابه
A stable iteration to the matrix inversion
The matrix inversion plays a signifcant role in engineering and sciences. Any nonsingular square matrix has a unique inverse which can readily be evaluated via numerical techniques such as direct methods, decomposition scheme, iterative methods, etc. In this research article, first of all an algorithm which has fourth order rate of convergency with conditional stability will be proposed. ...
متن کاملRecursion, Iteration and Hume Scheduling
Converting programs from full or PR-Hume to FSMor HW-Hume involves transforming expression recursion to box iteration. However, this can add considerable overheads through unnecessary scheduling of other boxes dependent on the iteration output. Here we explore how analysis of output behaviour can identify boxes which may be executed independently of normal super-step scheduling, without affecti...
متن کاملNatural language - no infinity and probably no recursion
We question the need for recursion in human cognitive processing by arguing that a generally simpler and less resource demanding process – iteration – is sufficient to account for human natural language and arithmetic performance. We claim that the only motivation for recursion, the infinity in natural language and arithmetic competence, is equally approachable by iteration and recursion. Secon...
متن کاملRecursion Schemes From
Within the setting of the categorical approach to total functional programming, we introduce a \many-in-one" recursion scheme that neatly uniies a variety of seemingly diverging strengthenings of the basic recursion scheme of iteration. The new scheme is doubly generic: in addition to being parametric in a functor capturing the signature of an inductive type, it is also parametric in a comonad ...
متن کاملSyntactic recursion and iteration
The nature and origin of syntactic recursion in natural languages is a topical problem. Important recent contributions include those of Johansson (2005), Parker (2006), Tomalin (2006; 2007), and Heine and Kuteva (2007). Syntactic recursion will here be discussed especially in relation to its cognate concept of iteration. Their basic common feature is plain structural repetition: “keep on emitti...
متن کاملBar Recursion and Products of Selection Functions
We show how two iterated products of selection functions can both be used in conjunction with system T to interpret, via the dialectica interpretation and modified realizability, full classical analysis. We also show that one iterated product is equivalent over system T to Spector’s bar recursion, whereas the other is T-equivalent to modified bar recursion. Modified bar recursion itself is show...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید
ثبت ناماگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید
ورودعنوان ژورنال:
- Lisp and Symbolic Computation
دوره 7 شماره
صفحات -
تاریخ انتشار 1994